package com.ship.contract.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.ship.common.core.base.Constant;
import com.ship.common.business.service.impl.BaseServiceImpl;
import com.ship.contract.mapper.ConstantMapper;
import com.ship.contract.service.KonstService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author tangshixuan
 * @date 2023-8-30
 */
@Service
public class KonstServiceImpl extends BaseServiceImpl<ConstantMapper, Constant> implements KonstService {

    @Autowired
    private ConstantMapper constantMapper;
    @Override
    public List<Constant> listByType(String type) {
        QueryWrapper<Constant> queryWrapper = new QueryWrapper<>();
        queryWrapper.eq("type",type);
        return constantMapper.selectList(queryWrapper);
    }
}
